module.exports = {
  type: {
    type: Array,
    default: 'images',
    name: '轮播类型',
    filedType: 'select',
    options: [
      {
        name: '内容列表',
        value: 'content'
      },
      {
        name: '图片列表',
        value: 'images'
      },
      {
        name: '新闻列表',
        value: 'text'
      }
    ]
  },

  watchContent: {
    type: Boolean,
    default: false,
    name: '监控内容改变',
    nameTip: '内容改变时，重新初始化轮播容器，在动态添加内容时有可能需要打开',
    filedType: 'switch',
    vif: {
      key: 'type',
      value: 'content'
    }
  },

  imageListFromProp: {
    type: Array,
    default () {
      return []
    },
    name: '图片列表',
    nameTip: '可在数据管理中设置图片列表，优先级高于当前属性的优先级，如果上传的图片需要指定跳转地址，可先在此处上传图片，再复制上传的地址，然后在数据管理中设置图片跳转的href',
    filedType: 'file',
    limit: 1,
    maxSize: 1024,
    vif: {
      key: 'type',
      value: 'images'
    }
  },

  textListFromProp: {
    type: Array,
    default () {
      return []
    },
    name: '新闻列表',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  imageListFromApi: {
    type: Array,
    default () {
      return [
        {
          title: '图片',
          url: '/xxx/demo.png',
          backgroundColor: '#190044',
          href: 'http://www.baidu.com',
          target: '_blank'
        },
        {
          title: '可跳转的图片',
          url: '/xxx/demo.png',
          href: './index.html',
          backgroundColor: 'red'
        }
      ]
    },
    name: '图片列表(从api获取)',
    nameTip: '此处图片列表的优先级高于属性中的图片列表的优先级，以下为属性解释：\nurl:图片路径，必须\ntitle:图片标题\nbackgroundColor:图片背景色\nhref:图片跳转地址\ntarget:是否在当前窗口打开链接,默认在当前窗口打开，为_blank时在新窗口打开',
    filedType: 'api',
    vif: {
      key: 'type',
      value: 'images'
    }
  },

  textListFromApi: {
    type: Array,
    default () {
      return [
        {
          id: 1,
          title: '这是新闻标题这是新闻标题这是新闻标题这是新闻标题这是新闻标题',
          classfiy: '校园动态',
          href: '/detail.html',
          target: '_blank',
          date: '2020-10-20'
        },
        {
          id: 2,
          title: '这是新闻标题',
          href: '/detail.html',
          target: '_blank',
          date: '2020-10-20',
          cover: '/2020/11/17/0b312406-383a-46cc-9c5a-227a7da87ba5/logo.png'
        },
        {
          id: 3,
          title: '这是新闻标题2',
          href: '/detail.html',
          target: '_blank',
          date: '2020-10-20'
        }
      ]
    },
    name: '新闻列表(从api获取)',
    filedType: 'api',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  hasBeforeDot: {
    type: Boolean,
    default: true,
    name: '列表标题序列',
    filedType: 'switch',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  dotType: {
    type: String,
    default: 'circle',
    name: '标题序列样式',
    filedType: 'select',
    options: [
      {
        name: '圆点',
        value: 'circle'
      },
      {
        name: '正方形',
        value: 'square'
      },
      {
        name: '环形',
        value: 'ring'
      }
    ],
    vif: {
      key: 'hasBeforeDot',
      value: true
    }
  },

  dotColor: {
    type: String,
    default: '#999',
    name: '标题序列颜色',
    filedType: 'color',
    vif: {
      key: 'hasBeforeDot',
      value: true
    }
  },

  dotHoverColor: {
    type: String,
    default: '#f12e22',
    name: '标题序列划过颜色',
    filedType: 'color',
    vif: {
      key: 'hasBeforeDot',
      value: true
    }
  },

  dotSize: {
    type: String,
    default: '5px',
    name: '标题序列大小',
    filedType: 'string',
    vif: {
      key: 'hasBeforeDot',
      value: true
    }
  },

  titleColor: {
    type: String,
    default: '#333',
    name: '标题颜色',
    filedType: 'color',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  titleHoverColor: {
    type: String,
    default: '#f12e22',
    name: '标题划过颜色',
    filedType: 'color',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  titleFontSize: {
    type: String,
    default: '16px',
    name: '标题字体大小',
    filedType: 'string',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  hasDate: {
    type: Boolean,
    default: true,
    name: '日期',
    filedType: 'switch',
    vif: {
      key: 'type',
      value: 'text'
    }
  },

  dateColor: {
    type: String,
    default: '#999',
    name: '日期颜色',
    filedType: 'color',
    vif: {
      key: 'hasDate',
      value: true
    }
  },

  dateFontSize: {
    type: String,
    default: '12px',
    name: '日期字体大小',
    filedType: 'string',
    vif: {
      key: 'hasDate',
      value: true
    }
  },

  imageFillType: {
    type: String,
    default: 'contain',
    name: '图片填充方式',
    filedType: 'select',
    options: [
      {
        name: '填充(默认)',
        value: 'fill'
      },
      {
        name: '包含',
        value: 'contain'
      },
      {
        name: '覆盖',
        value: 'cover'
      },
      {
        name: '按长宽最小值保留长宽比',
        value: 'scale-down'
      },
      {
        name: '不重置',
        value: 'none'
      }
    ],
    vif: {
      key: 'type',
      value: 'images'
    }
  },

  imageTitleVisibal: {
    type: Boolean,
    default: false,
    name: '是否显示图片标题',
    filedType: 'switch'
  },

  imageTitleHeight: {
    type: String,
    default: '',
    name: '图片标题高度',
    filedType: 'string',
    vif: {
      key: 'imageTitleVisibal',
      value: true
    }
  },

  imageTitleBg: {
    type: String,
    default: '',
    name: '图片标题背景',
    filedType: 'color',
    vif: {
      key: 'imageTitleVisibal',
      value: true
    }
  },

  imageTitleColor: {
    type: String,
    default: '',
    name: '图片标题文本颜色',
    filedType: 'color',
    vif: {
      key: 'imageTitleVisibal',
      value: true
    }
  },

  imageTitleFontSize: {
    type: String,
    default: '',
    name: '图片标题文本大小',
    filedType: 'string',
    vif: {
      key: 'imageTitleVisibal',
      value: true
    }
  },

  direction: {
    type: Array,
    default: 'horizontal',
    name: '滑动方向',
    filedType: 'select',
    options: [
      {
        name: '水平滑动',
        value: 'horizontal'
      },
      {
        name: '垂直滑动',
        value: 'vertical'
      }
    ]
  },

  autoplay: {
    type: Boolean,
    default: true,
    name: '开启自动切换',
    filedType: 'switch'
  },

  autoplayTime: {
    type: String,
    default: '2000',
    name: '自动播放间隔(ms)',
    nameTip: '不设置或设置为0时不会自动播放',
    filedType: 'string',
    vif: {
      key: 'autoplay',
      value: true
    }
  },

  disableOnInteraction: {
    type: Boolean,
    default: false,
    name: '用户交互后禁止自动切换',
    filedType: 'switch',
    vif: {
      key: 'autoplay',
      value: true
    }
  },

  slidesPerView: {
    type: String,
    default: '1',
    name: '同时显示多少项',
    filedType: 'string'
  },

  initialSlide: {
    type: String,
    default: '0',
    name: '默认显示第几项',
    filedType: 'string'
  },

  loop: {
    type: Boolean,
    default: false,
    name: '是否启用循环模式',
    nameTip: '注意：设计页面时开启不能看到效果，请预览页面或在最终的站点页面中查看效果',
    filedType: 'switch'
  },

  wheelEnable: {
    type: Boolean,
    default: false,
    name: '启用滑轮滚动',
    filedType: 'switch'
  },

  paginationEnable: {
    type: String,
    default: true,
    name: '是否需要分页器',
    filedType: 'switch'
  },

  paginationMarkType: {
    type: Array,
    default: 'circle',
    name: '分页标识类型',
    filedType: 'select',
    options: [
      {
        name: '圆圈',
        value: 'circle'
      },
      {
        name: '圆点',
        value: 'dot'
      },
      {
        name: '方块',
        value: 'square'
      }
    ],
    vif: {
      key: 'paginationEnable',
      value: true
    }
  },

  paginationMarkSize: {
    type: String,
    default: '8px',
    name: '分页标识大小',
    filedType: 'string',
    vif: {
      key: 'paginationEnable',
      value: true
    }
  },

  paginationMarColor: {
    type: String,
    default: '#cccccc',
    name: '默认分页标识颜色',
    filedType: 'color',
    vif: {
      key: 'paginationEnable',
      value: true
    }
  },

  speed: {
    type: String,
    default: '300',
    name: '切换速度设置',
    filedType: 'string'
  },

  paginationMarActiveColor: {
    type: String,
    default: '#007aff',
    name: '当前分页标识颜色',
    filedType: 'color',
    vif: {
      key: 'paginationEnable',
      value: true
    }
  },

  buttonEnable: {
    type: Boolean,
    default: true,
    name: '是否需要前进后退按钮',
    filedType: 'switch'
  },

  buttonOUtEnable: {
    type: Boolean,
    default: false,
    name: '是否在外面显示',
    filedType: 'switch',
    vif: {
      key: 'buttonEnable',
      value: true
    }
  },

  prevIcon: {
    type: String,
    default: [],
    name: '后退按钮图标',
    filedType: 'file',
    limit: 1,
    maxSize: 1024,
    vif: {
      key: 'buttonEnable',
      value: true
    }
  },

  nextIcon: {
    type: String,
    default: [],
    name: '前进按钮图标',
    filedType: 'file',
    limit: 1,
    maxSize: 1024,
    vif: {
      key: 'buttonEnable',
      value: true
    }
  },

  iconSize: {
    type: String,
    default: '50px',
    name: '按钮图标大小',
    filedType: 'string',
    vif: {
      key: 'buttonEnable',
      value: true
    }
  },

  iconWidth: {
    type: String,
    default: '.72rem',
    name: '按钮图标宽度',
    filedType: 'string',
    vif: {
      key: 'buttonEnable',
      value: true
    }
  },

  enableSide3d: {
    type: String,
    default: false,
    name: '启用左右侧边项弱3d效果',
    filedType: 'switch'
  },

  perspective: {
    type: String,
    default: '500px',
    name: '透视距离',
    filedType: 'string',
    vif: {
      key: 'enableSide3d',
      value: true
    }
  },

  rotateY: {
    type: String,
    default: '20',
    name: '垂直轴旋转角度',
    filedType: 'string',
    vif: {
      key: 'enableSide3d',
      value: true
    }
  },

  translateX: {
    type: String,
    default: '50px',
    name: '水平平移',
    filedType: 'string',
    vif: {
      key: 'enableSide3d',
      value: true
    }
  },

  scale: {
    type: String,
    default: '0.85',
    name: '缩放',
    filedType: 'string',
    vif: {
      key: 'enableSide3d',
      value: true
    }
  },

  slideFn: {
    type: Function,
    default: '',
    name: '内容项滑动时回调函数',
    nameTip: '函数的第一个参数为当前的内容项索引，第二个参数为swiper本身',
    filedType: 'function'
  },

  reachEndFn: {
    type: Function,
    default: '',
    name: '滑动到最后一项时回调函数',
    nameTip: '函数的第一个参数为当前的内容项索引，第二个参数为swiper本身',
    filedType: 'function'
  }
}
